package com.zj.fx.model.info;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;

import cn.hutool.core.util.StrUtil;

/**
 * 必备条件指标库表 InfoNecessaryExample
 *
 * @author SQL_自动生成
 * @date 2023-06-27 15:21:06
 */
public class InfoNecessaryExample {

    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    public InfoNecessaryExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }


        public Criteria andIdIsNull() {
            addCriterion("id is null");
            return (Criteria) this;
        }

        public Criteria andIdIsNotNull() {
            addCriterion("id is not null");
            return (Criteria) this;
        }

        public Criteria andIdEqualTo(String value) {
            addCriterion("id =", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotEqualTo(String value) {
            addCriterion("id <>", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdGreaterThan(String value) {
            addCriterion("id >", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdGreaterThanOrEqualTo(String value) {
            addCriterion("id >=", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLessThan(String value) {
            addCriterion("id <", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLessThanOrEqualTo(String value) {
            addCriterion("id <=", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLike(String value) {
            addCriterion("id like", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotLike(String value) {
            addCriterion("id not like", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdIn(List<String> values) {
            addCriterion("id in", values, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotIn(List<String> values) {
            addCriterion("id not in", values, "id");
            return (Criteria) this;
        }

        public Criteria andIdBetween(String value1, String value2) {
            addCriterion("id between", value1, value2, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotBetween(String value1, String value2) {
            addCriterion("id not between", value1, value2, "id");
            return (Criteria) this;
        }


        public Criteria andNumIsNull() {
            addCriterion("num is null");
            return (Criteria) this;
        }

        public Criteria andNumIsNotNull() {
            addCriterion("num is not null");
            return (Criteria) this;
        }

        public Criteria andNumEqualTo(String value) {
            addCriterion("num =", value, "num");
            return (Criteria) this;
        }

        public Criteria andNumNotEqualTo(String value) {
            addCriterion("num <>", value, "num");
            return (Criteria) this;
        }

        public Criteria andNumGreaterThan(String value) {
            addCriterion("num >", value, "num");
            return (Criteria) this;
        }

        public Criteria andNumGreaterThanOrEqualTo(String value) {
            addCriterion("num >=", value, "num");
            return (Criteria) this;
        }

        public Criteria andNumLessThan(String value) {
            addCriterion("num <", value, "num");
            return (Criteria) this;
        }

        public Criteria andNumLessThanOrEqualTo(String value) {
            addCriterion("num <=", value, "num");
            return (Criteria) this;
        }

        public Criteria andNumLike(String value) {
            addCriterion("num like", value, "num");
            return (Criteria) this;
        }

        public Criteria andNumNotLike(String value) {
            addCriterion("num not like", value, "num");
            return (Criteria) this;
        }

        public Criteria andNumIn(List<String> values) {
            addCriterion("num in", values, "num");
            return (Criteria) this;
        }

        public Criteria andNumNotIn(List<String> values) {
            addCriterion("num not in", values, "num");
            return (Criteria) this;
        }

        public Criteria andNumBetween(String value1, String value2) {
            addCriterion("num between", value1, value2, "num");
            return (Criteria) this;
        }

        public Criteria andNumNotBetween(String value1, String value2) {
            addCriterion("num not between", value1, value2, "num");
            return (Criteria) this;
        }


        public Criteria andFirstProjectIsNull() {
            addCriterion("first_project is null");
            return (Criteria) this;
        }

        public Criteria andFirstProjectIsNotNull() {
            addCriterion("first_project is not null");
            return (Criteria) this;
        }

        public Criteria andFirstProjectEqualTo(String value) {
            addCriterion("first_project =", value, "firstProject");
            return (Criteria) this;
        }

        public Criteria andFirstProjectNotEqualTo(String value) {
            addCriterion("first_project <>", value, "firstProject");
            return (Criteria) this;
        }

        public Criteria andFirstProjectGreaterThan(String value) {
            addCriterion("first_project >", value, "firstProject");
            return (Criteria) this;
        }

        public Criteria andFirstProjectGreaterThanOrEqualTo(String value) {
            addCriterion("first_project >=", value, "firstProject");
            return (Criteria) this;
        }

        public Criteria andFirstProjectLessThan(String value) {
            addCriterion("first_project <", value, "firstProject");
            return (Criteria) this;
        }

        public Criteria andFirstProjectLessThanOrEqualTo(String value) {
            addCriterion("first_project <=", value, "firstProject");
            return (Criteria) this;
        }

        public Criteria andFirstProjectLike(String value) {
            addCriterion("first_project like", value, "firstProject");
            return (Criteria) this;
        }

        public Criteria andFirstProjectNotLike(String value) {
            addCriterion("first_project not like", value, "firstProject");
            return (Criteria) this;
        }

        public Criteria andFirstProjectIn(List<String> values) {
            addCriterion("first_project in", values, "firstProject");
            return (Criteria) this;
        }

        public Criteria andFirstProjectNotIn(List<String> values) {
            addCriterion("first_project not in", values, "firstProject");
            return (Criteria) this;
        }

        public Criteria andFirstProjectBetween(String value1, String value2) {
            addCriterion("first_project between", value1, value2, "firstProject");
            return (Criteria) this;
        }

        public Criteria andFirstProjectNotBetween(String value1, String value2) {
            addCriterion("first_project not between", value1, value2, "firstProject");
            return (Criteria) this;
        }


        public Criteria andSecondProjectIsNull() {
            addCriterion("second_project is null");
            return (Criteria) this;
        }

        public Criteria andSecondProjectIsNotNull() {
            addCriterion("second_project is not null");
            return (Criteria) this;
        }

        public Criteria andSecondProjectEqualTo(String value) {
            addCriterion("second_project =", value, "secondProject");
            return (Criteria) this;
        }

        public Criteria andSecondProjectNotEqualTo(String value) {
            addCriterion("second_project <>", value, "secondProject");
            return (Criteria) this;
        }

        public Criteria andSecondProjectGreaterThan(String value) {
            addCriterion("second_project >", value, "secondProject");
            return (Criteria) this;
        }

        public Criteria andSecondProjectGreaterThanOrEqualTo(String value) {
            addCriterion("second_project >=", value, "secondProject");
            return (Criteria) this;
        }

        public Criteria andSecondProjectLessThan(String value) {
            addCriterion("second_project <", value, "secondProject");
            return (Criteria) this;
        }

        public Criteria andSecondProjectLessThanOrEqualTo(String value) {
            addCriterion("second_project <=", value, "secondProject");
            return (Criteria) this;
        }

        public Criteria andSecondProjectLike(String value) {
            addCriterion("second_project like", value, "secondProject");
            return (Criteria) this;
        }

        public Criteria andSecondProjectNotLike(String value) {
            addCriterion("second_project not like", value, "secondProject");
            return (Criteria) this;
        }

        public Criteria andSecondProjectIn(List<String> values) {
            addCriterion("second_project in", values, "secondProject");
            return (Criteria) this;
        }

        public Criteria andSecondProjectNotIn(List<String> values) {
            addCriterion("second_project not in", values, "secondProject");
            return (Criteria) this;
        }

        public Criteria andSecondProjectBetween(String value1, String value2) {
            addCriterion("second_project between", value1, value2, "secondProject");
            return (Criteria) this;
        }

        public Criteria andSecondProjectNotBetween(String value1, String value2) {
            addCriterion("second_project not between", value1, value2, "secondProject");
            return (Criteria) this;
        }


        public Criteria andTestModeIsNull() {
            addCriterion("test_mode is null");
            return (Criteria) this;
        }

        public Criteria andTestModeIsNotNull() {
            addCriterion("test_mode is not null");
            return (Criteria) this;
        }

        public Criteria andTestModeEqualTo(String value) {
            addCriterion("test_mode =", value, "testMode");
            return (Criteria) this;
        }

        public Criteria andTestModeNotEqualTo(String value) {
            addCriterion("test_mode <>", value, "testMode");
            return (Criteria) this;
        }

        public Criteria andTestModeGreaterThan(String value) {
            addCriterion("test_mode >", value, "testMode");
            return (Criteria) this;
        }

        public Criteria andTestModeGreaterThanOrEqualTo(String value) {
            addCriterion("test_mode >=", value, "testMode");
            return (Criteria) this;
        }

        public Criteria andTestModeLessThan(String value) {
            addCriterion("test_mode <", value, "testMode");
            return (Criteria) this;
        }

        public Criteria andTestModeLessThanOrEqualTo(String value) {
            addCriterion("test_mode <=", value, "testMode");
            return (Criteria) this;
        }

        public Criteria andTestModeLike(String value) {
            addCriterion("test_mode like", value, "testMode");
            return (Criteria) this;
        }

        public Criteria andTestModeNotLike(String value) {
            addCriterion("test_mode not like", value, "testMode");
            return (Criteria) this;
        }

        public Criteria andTestModeIn(List<String> values) {
            addCriterion("test_mode in", values, "testMode");
            return (Criteria) this;
        }

        public Criteria andTestModeNotIn(List<String> values) {
            addCriterion("test_mode not in", values, "testMode");
            return (Criteria) this;
        }

        public Criteria andTestModeBetween(String value1, String value2) {
            addCriterion("test_mode between", value1, value2, "testMode");
            return (Criteria) this;
        }

        public Criteria andTestModeNotBetween(String value1, String value2) {
            addCriterion("test_mode not between", value1, value2, "testMode");
            return (Criteria) this;
        }


        public Criteria andEvaluationPeriodIsNull() {
            addCriterion("evaluation_period is null");
            return (Criteria) this;
        }

        public Criteria andEvaluationPeriodIsNotNull() {
            addCriterion("evaluation_period is not null");
            return (Criteria) this;
        }

        public Criteria andEvaluationPeriodEqualTo(String value) {
            addCriterion("evaluation_period =", value, "evaluationPeriod");
            return (Criteria) this;
        }

        public Criteria andEvaluationPeriodNotEqualTo(String value) {
            addCriterion("evaluation_period <>", value, "evaluationPeriod");
            return (Criteria) this;
        }

        public Criteria andEvaluationPeriodGreaterThan(String value) {
            addCriterion("evaluation_period >", value, "evaluationPeriod");
            return (Criteria) this;
        }

        public Criteria andEvaluationPeriodGreaterThanOrEqualTo(String value) {
            addCriterion("evaluation_period >=", value, "evaluationPeriod");
            return (Criteria) this;
        }

        public Criteria andEvaluationPeriodLessThan(String value) {
            addCriterion("evaluation_period <", value, "evaluationPeriod");
            return (Criteria) this;
        }

        public Criteria andEvaluationPeriodLessThanOrEqualTo(String value) {
            addCriterion("evaluation_period <=", value, "evaluationPeriod");
            return (Criteria) this;
        }

        public Criteria andEvaluationPeriodLike(String value) {
            addCriterion("evaluation_period like", value, "evaluationPeriod");
            return (Criteria) this;
        }

        public Criteria andEvaluationPeriodNotLike(String value) {
            addCriterion("evaluation_period not like", value, "evaluationPeriod");
            return (Criteria) this;
        }

        public Criteria andEvaluationPeriodIn(List<String> values) {
            addCriterion("evaluation_period in", values, "evaluationPeriod");
            return (Criteria) this;
        }

        public Criteria andEvaluationPeriodNotIn(List<String> values) {
            addCriterion("evaluation_period not in", values, "evaluationPeriod");
            return (Criteria) this;
        }

        public Criteria andEvaluationPeriodBetween(String value1, String value2) {
            addCriterion("evaluation_period between", value1, value2, "evaluationPeriod");
            return (Criteria) this;
        }

        public Criteria andEvaluationPeriodNotBetween(String value1, String value2) {
            addCriterion("evaluation_period not between", value1, value2, "evaluationPeriod");
            return (Criteria) this;
        }


        public Criteria andResDeptIdIsNull() {
            addCriterion("res_dept_id is null");
            return (Criteria) this;
        }

        public Criteria andResDeptIdIsNotNull() {
            addCriterion("res_dept_id is not null");
            return (Criteria) this;
        }

        public Criteria andResDeptIdEqualTo(String value) {
            addCriterion("res_dept_id =", value, "resDeptId");
            return (Criteria) this;
        }

        public Criteria andResDeptIdNotEqualTo(String value) {
            addCriterion("res_dept_id <>", value, "resDeptId");
            return (Criteria) this;
        }

        public Criteria andResDeptIdGreaterThan(String value) {
            addCriterion("res_dept_id >", value, "resDeptId");
            return (Criteria) this;
        }

        public Criteria andResDeptIdGreaterThanOrEqualTo(String value) {
            addCriterion("res_dept_id >=", value, "resDeptId");
            return (Criteria) this;
        }

        public Criteria andResDeptIdLessThan(String value) {
            addCriterion("res_dept_id <", value, "resDeptId");
            return (Criteria) this;
        }

        public Criteria andResDeptIdLessThanOrEqualTo(String value) {
            addCriterion("res_dept_id <=", value, "resDeptId");
            return (Criteria) this;
        }

        public Criteria andResDeptIdLike(String value) {
            addCriterion("res_dept_id like", value, "resDeptId");
            return (Criteria) this;
        }

        public Criteria andResDeptIdNotLike(String value) {
            addCriterion("res_dept_id not like", value, "resDeptId");
            return (Criteria) this;
        }

        public Criteria andResDeptIdIn(List<String> values) {
            addCriterion("res_dept_id in", values, "resDeptId");
            return (Criteria) this;
        }

        public Criteria andResDeptIdNotIn(List<String> values) {
            addCriterion("res_dept_id not in", values, "resDeptId");
            return (Criteria) this;
        }

        public Criteria andResDeptIdBetween(String value1, String value2) {
            addCriterion("res_dept_id between", value1, value2, "resDeptId");
            return (Criteria) this;
        }

        public Criteria andResDeptIdNotBetween(String value1, String value2) {
            addCriterion("res_dept_id not between", value1, value2, "resDeptId");
            return (Criteria) this;
        }


        public Criteria andSupportingFileMemoIsNull() {
            addCriterion("supporting_file_memo is null");
            return (Criteria) this;
        }

        public Criteria andSupportingFileMemoIsNotNull() {
            addCriterion("supporting_file_memo is not null");
            return (Criteria) this;
        }

        public Criteria andSupportingFileMemoEqualTo(String value) {
            addCriterion("supporting_file_memo =", value, "supportingFileMemo");
            return (Criteria) this;
        }

        public Criteria andSupportingFileMemoNotEqualTo(String value) {
            addCriterion("supporting_file_memo <>", value, "supportingFileMemo");
            return (Criteria) this;
        }

        public Criteria andSupportingFileMemoGreaterThan(String value) {
            addCriterion("supporting_file_memo >", value, "supportingFileMemo");
            return (Criteria) this;
        }

        public Criteria andSupportingFileMemoGreaterThanOrEqualTo(String value) {
            addCriterion("supporting_file_memo >=", value, "supportingFileMemo");
            return (Criteria) this;
        }

        public Criteria andSupportingFileMemoLessThan(String value) {
            addCriterion("supporting_file_memo <", value, "supportingFileMemo");
            return (Criteria) this;
        }

        public Criteria andSupportingFileMemoLessThanOrEqualTo(String value) {
            addCriterion("supporting_file_memo <=", value, "supportingFileMemo");
            return (Criteria) this;
        }

        public Criteria andSupportingFileMemoLike(String value) {
            addCriterion("supporting_file_memo like", value, "supportingFileMemo");
            return (Criteria) this;
        }

        public Criteria andSupportingFileMemoNotLike(String value) {
            addCriterion("supporting_file_memo not like", value, "supportingFileMemo");
            return (Criteria) this;
        }

        public Criteria andSupportingFileMemoIn(List<String> values) {
            addCriterion("supporting_file_memo in", values, "supportingFileMemo");
            return (Criteria) this;
        }

        public Criteria andSupportingFileMemoNotIn(List<String> values) {
            addCriterion("supporting_file_memo not in", values, "supportingFileMemo");
            return (Criteria) this;
        }

        public Criteria andSupportingFileMemoBetween(String value1, String value2) {
            addCriterion("supporting_file_memo between", value1, value2, "supportingFileMemo");
            return (Criteria) this;
        }

        public Criteria andSupportingFileMemoNotBetween(String value1, String value2) {
            addCriterion("supporting_file_memo not between", value1, value2, "supportingFileMemo");
            return (Criteria) this;
        }


        public Criteria andRemarkIsNull() {
            addCriterion("remark is null");
            return (Criteria) this;
        }

        public Criteria andRemarkIsNotNull() {
            addCriterion("remark is not null");
            return (Criteria) this;
        }

        public Criteria andRemarkEqualTo(String value) {
            addCriterion("remark =", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkNotEqualTo(String value) {
            addCriterion("remark <>", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkGreaterThan(String value) {
            addCriterion("remark >", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkGreaterThanOrEqualTo(String value) {
            addCriterion("remark >=", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkLessThan(String value) {
            addCriterion("remark <", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkLessThanOrEqualTo(String value) {
            addCriterion("remark <=", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkLike(String value) {
            addCriterion("remark like", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkNotLike(String value) {
            addCriterion("remark not like", value, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkIn(List<String> values) {
            addCriterion("remark in", values, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkNotIn(List<String> values) {
            addCriterion("remark not in", values, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkBetween(String value1, String value2) {
            addCriterion("remark between", value1, value2, "remark");
            return (Criteria) this;
        }

        public Criteria andRemarkNotBetween(String value1, String value2) {
            addCriterion("remark not between", value1, value2, "remark");
            return (Criteria) this;
        }


        public Criteria andResDeptNameIsNull() {
            addCriterion("res_dept_name is null");
            return (Criteria) this;
        }

        public Criteria andResDeptNameIsNotNull() {
            addCriterion("res_dept_name is not null");
            return (Criteria) this;
        }

        public Criteria andResDeptNameEqualTo(String value) {
            addCriterion("res_dept_name =", value, "resDeptName");
            return (Criteria) this;
        }

        public Criteria andResDeptNameNotEqualTo(String value) {
            addCriterion("res_dept_name <>", value, "resDeptName");
            return (Criteria) this;
        }

        public Criteria andResDeptNameGreaterThan(String value) {
            addCriterion("res_dept_name >", value, "resDeptName");
            return (Criteria) this;
        }

        public Criteria andResDeptNameGreaterThanOrEqualTo(String value) {
            addCriterion("res_dept_name >=", value, "resDeptName");
            return (Criteria) this;
        }

        public Criteria andResDeptNameLessThan(String value) {
            addCriterion("res_dept_name <", value, "resDeptName");
            return (Criteria) this;
        }

        public Criteria andResDeptNameLessThanOrEqualTo(String value) {
            addCriterion("res_dept_name <=", value, "resDeptName");
            return (Criteria) this;
        }

        public Criteria andResDeptNameLike(String value) {
            addCriterion("res_dept_name like", value, "resDeptName");
            return (Criteria) this;
        }

        public Criteria andResDeptNameNotLike(String value) {
            addCriterion("res_dept_name not like", value, "resDeptName");
            return (Criteria) this;
        }

        public Criteria andResDeptNameIn(List<String> values) {
            addCriterion("res_dept_name in", values, "resDeptName");
            return (Criteria) this;
        }

        public Criteria andResDeptNameNotIn(List<String> values) {
            addCriterion("res_dept_name not in", values, "resDeptName");
            return (Criteria) this;
        }

        public Criteria andResDeptNameBetween(String value1, String value2) {
            addCriterion("res_dept_name between", value1, value2, "resDeptName");
            return (Criteria) this;
        }

        public Criteria andResDeptNameNotBetween(String value1, String value2) {
            addCriterion("res_dept_name not between", value1, value2, "resDeptName");
            return (Criteria) this;
        }


        public Criteria andLikeQuery(InfoNecessary record) {
            List<String> list = new ArrayList<String>();
            List<String> list2 = new ArrayList<String>();
            StringBuffer buffer = new StringBuffer();
            if (record.getId() != null && StrUtil.isNotEmpty(record.getId().toString())) {
                list.add("ifnull(id,'')");
            }
            if (record.getNum() != null && StrUtil.isNotEmpty(record.getNum().toString())) {
                list.add("ifnull(num,'')");
            }
            if (record.getFirstProject() != null && StrUtil.isNotEmpty(record.getFirstProject().toString())) {
                list.add("ifnull(first_project,'')");
            }
            if (record.getSecondProject() != null && StrUtil.isNotEmpty(record.getSecondProject().toString())) {
                list.add("ifnull(second_project,'')");
            }
            if (record.getTestMode() != null && StrUtil.isNotEmpty(record.getTestMode().toString())) {
                list.add("ifnull(test_mode,'')");
            }
            if (record.getEvaluationPeriod() != null && StrUtil.isNotEmpty(record.getEvaluationPeriod().toString())) {
                list.add("ifnull(evaluation_period,'')");
            }
            if (record.getResDeptId() != null && StrUtil.isNotEmpty(record.getResDeptId().toString())) {
                list.add("ifnull(res_dept_id,'')");
            }
            if (record.getSupportingFileMemo() != null && StrUtil.isNotEmpty(record.getSupportingFileMemo().toString())) {
                list.add("ifnull(supporting_file_memo,'')");
            }
            if (record.getRemark() != null && StrUtil.isNotEmpty(record.getRemark().toString())) {
                list.add("ifnull(remark,'')");
            }
            if (record.getResDeptName() != null && StrUtil.isNotEmpty(record.getResDeptName().toString())) {
                list.add("ifnull(res_dept_name,'')");
            }
            if (record.getId() != null && StrUtil.isNotEmpty(record.getId().toString())) {
                list2.add("'%" + record.getId() + "%'");
            }
            if (record.getNum() != null && StrUtil.isNotEmpty(record.getNum().toString())) {
                list2.add("'%" + record.getNum() + "%'");
            }
            if (record.getFirstProject() != null && StrUtil.isNotEmpty(record.getFirstProject().toString())) {
                list2.add("'%" + record.getFirstProject() + "%'");
            }
            if (record.getSecondProject() != null && StrUtil.isNotEmpty(record.getSecondProject().toString())) {
                list2.add("'%" + record.getSecondProject() + "%'");
            }
            if (record.getTestMode() != null && StrUtil.isNotEmpty(record.getTestMode().toString())) {
                list2.add("'%" + record.getTestMode() + "%'");
            }
            if (record.getEvaluationPeriod() != null && StrUtil.isNotEmpty(record.getEvaluationPeriod().toString())) {
                list2.add("'%" + record.getEvaluationPeriod() + "%'");
            }
            if (record.getResDeptId() != null && StrUtil.isNotEmpty(record.getResDeptId().toString())) {
                list2.add("'%" + record.getResDeptId() + "%'");
            }
            if (record.getSupportingFileMemo() != null && StrUtil.isNotEmpty(record.getSupportingFileMemo().toString())) {
                list2.add("'%" + record.getSupportingFileMemo() + "%'");
            }
            if (record.getRemark() != null && StrUtil.isNotEmpty(record.getRemark().toString())) {
                list2.add("'%" + record.getRemark() + "%'");
            }
            if (record.getResDeptName() != null && StrUtil.isNotEmpty(record.getResDeptName().toString())) {
                list2.add("'%" + record.getResDeptName() + "%'");
            }
            buffer.append(" CONCAT(");
            buffer.append(StrUtil.join(",", list));
            buffer.append(")");
            buffer.append(" like CONCAT(");
            buffer.append(StrUtil.join(",", list2));
            buffer.append(")");
            if (!" CONCAT() like CONCAT()".equals(buffer.toString())) {
                addCriterion(buffer.toString());
            }
            return (Criteria) this;
        }

        public Criteria andLikeQuery2(String searchText) {
            List<String> list = new ArrayList<String>();
            StringBuffer buffer = new StringBuffer();
            list.add("ifnull(id,'')");
            list.add("ifnull(num,'')");
            list.add("ifnull(first_project,'')");
            list.add("ifnull(second_project,'')");
            list.add("ifnull(test_mode,'')");
            list.add("ifnull(evaluation_period,'')");
            list.add("ifnull(res_dept_id,'')");
            list.add("ifnull(supporting_file_memo,'')");
            list.add("ifnull(remark,'')");
            list.add("ifnull(res_dept_name,'')");
            buffer.append(" CONCAT(");
            buffer.append(StrUtil.join(",", list));
            buffer.append(")");
            buffer.append("like '%");
            buffer.append(searchText);
            buffer.append("%'");
            addCriterion(buffer.toString());
            return (Criteria) this;
        }

    }

    public static class Criteria extends GeneratedCriteria {
        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}